import type {ICommonResponse} from "@/types/global";
import request from "@/utils/request";

export interface IGoodItem {
    goodsId: number,
    goodsName: string,
    goodsIntro: string,
    goodsCoverImg: string,
    sellingPrice: number,
    tag: string,
    goodsCarouselList: string[],
    originalPrice: number,
    goodsDetailContent: string
}

const getGoodDetailAPI = (goodsId: string): ICommonResponse<IGoodItem> => {
    return request({
        url: `/api/v1/goods/detail/${goodsId}`,
        method: "GET",
    })
}
export default getGoodDetailAPI